import Vue from 'vue';
import Router from 'vue-router';
import index from '@/pages/index.vue';
import details from '@/pages/details.vue';
import publish from '@/pages/details/publish.vue';
import prediction from '@/pages/details/prediction.vue';
import uploadfile from '@/pages/details/uploadfile.vue';
import scroller from '@/pages/details/scroller.vue';
import scrollerTrans from '@/pages/details/scrollerTranslate.vue';
import paginationTable from '@/pages/details/paginationTable.vue';

Vue.use(Router);

export default new Router({
  mode: 'hash',
  routes: [
    {
      path: '/',
      name: 'index',
      component: index
    },
    {
      path: '/details',
      name: 'details',
      component: details,
      children: [{
        name: 'publish',
        path: 'publish',
        component: publish
      }, {
        name: 'prediction',
        path: 'prediction',
        component: prediction
      }, {
        name: 'uploadfile',
        path: 'uploadfile',
        component: uploadfile
      }, {
        name: 'scroller',
        path: 'scroller',
        component: scroller
      }, {
        name: 'scrollerTrans',
        path: 'scrollerTrans',
        component: scrollerTrans
      }, {
        name: 'paginationTable',
        path: 'paginationTable',
        component: paginationTable
      }]
    }

  ]
});
